#include "addition.h"
#include "stdlib.h"

void add(double* a, double* b, double* c)
{
	LARGE_INTEGER freq;
	LARGE_INTEGER sQP, fQP;

	omp_set_dynamic(0);      
	omp_set_num_threads(2);

	QueryPerformanceFrequency(&freq);
	QueryPerformanceCounter(&sQP);

	#pragma omp parallel
	{
		#pragma omp for

	for(int i=0; i<NUM; ++i)
	{
		c[i] = sqrt(exp(sin(cos(exp(sin(a[i]) * cos(b[i]))))) * exp(sin(cos(exp(sin(a[i]) * cos(b[i]))))));
	}

	}

	QueryPerformanceCounter(&fQP);
		
	printf("parall: %lf \n\n",(fQP.QuadPart-sQP.QuadPart)/(double)freq.QuadPart);
}